'''
Created on May 14, 2012

@author: Vu Dao
'''
from selenium import webdriver
from Interface.loginPage import xpathUserName, xpathPassword, xpathBtnLogin

# login website
def loginWebsite(self,username,password):
    browser = self.browser
    element = browser.find_element_by_xpath(xpathUserName())
    element.clear()
    element.send_keys(username)
    element = browser.find_element_by_xpath(xpathPassword())
    element.clear()
    element.send_keys(password)
    element = browser.find_element_by_xpath(xpathBtnLogin())
    element.click()
    
